import $ from '@/utils/requset'

const getHomeApi = () => $.getAxios('homeApi.json')
const getGouwu = () => $.getAxios('homeApi/categories.json')
const getGreens = (url) => $.getAxios("homeApi/categoriesdetail/"+url)
const getEat = () => $.getAxios("recipe/allScene.json")
const getWhatEat = (url) => $.getAxios("recipe/menulist/"+url)
// const loginApi = ({tel=null,sms=null}) => $.postAxios('login',{tel,sms})
// 注册
const postRegist = ({ tel = null, password = null } ) => $.postAxios('regist', { tel, password })
// 登录
const postLogin = ({ sms = null, yzm = null } ) => $.postAxios('login', { sms, yzm })
export default {
    getHomeApi,
    getGouwu,
    getGreens,
    getEat,
    getWhatEat,
    postRegist,
    postLogin
}